install.sh: install into ~/.vcx instead of Bun's global manifest - #2
Merged
Conversation
Bun 1.4.0 refuses the global install on some machines with 'refusing to install dependency with unsafe name' once the global manifest carries entries from earlier installs. install.sh now installs vcx and Vercel CLI into ~/.vcx with a fresh manifest and links the bins into Bun's bin dir. Co-Authored-By: Claude Fable 5.1 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
On a Mac with Bun 1.4.0, the one-liner failed at the vcx step:
The same command passes on a fresh machine (Linux and the macOS CI job, same Bun version), so the trigger is the state of Bun's global package manifest on that machine. Bun 1.4.0 appends a new
vcx-clikey to the global manifest on everybun install -ginstead of replacing it, and a leftover entry from an earlier tarball install can poison every later global install.Fix
install.shno longer usesbun install --global. It writes a freshpackage.jsoninto~/.vcx(override withVCX_INSTALL_DIR) withvcx-cliandvercelas dependencies, runsbun installthere, and linksvcxinto Bun's global bin directory.vercelis linked too, but only when nothing on PATH already provides it. Re-running the script upgrades.Verified in fresh homes with Bun preinstalled and with the script installing Bun, plus a re-run. shellcheck clean.
🤖 Generated with Claude Code